/**
 Do not return anything, modify nums in-place instead.
 */
 function moveZeroes(nums: number[]): void {
    let length = nums.length,
        j = 0
    for(let i = 0;i<length;i++){
        if(nums[i]!==0){
            nums[j++] = nums[i]
        }
    }
    for(j;j<length;j++){
        nums[j]=0
    }
};